1. Field of the Invention
A method and system for recovering a system status, and more particularly to a method and system for recovering the system status to the same time point in a distributed database.
2. Description of Related Art
The rapid evolution of the internet technology change the way people use the internet, and through the exchange by the internet, people around the world can share information in real time, and zero distance. For example, most websites have transformed into the Web2.0 type. The biggest difference between Web2.0 and traditional website is the source of information. The operator of Web2.0 typically provides an information platform, and through the sharing by people to achieve the purpose of information spreading. Although the Web2.0 can get more timely and adequate information through the accumulation of knowledge, relatively, because the user provided information for a long time, the cumulative amount of data is much greater than the resources required for the traditional sites, which resulting in system capacity overloaded.
In order to solve the above problems, the technology of non-relational database (No SQL) is gradually applied to store a variety of big data. Compared to the traditional relational database, the advantage of the non-relational database is that it can be horizontally expanded, that is, the elasticity of capacity of such database. When the database is overloaded, the capacity can be adjusted and expanded its capacity at any time. The common non-relational database is HBase, and the HBase is a distributed database. The HBase uses Apache Hadoop as a file system. HBase is divided into the primary server and the region server. The primary server and the region server are connected. When the primary server detects that one of the region server is damaged, it can recover the data in the region server to the status stored previously.
In the current HBase system, although the primary server can automatically detects the damage of the region server and recover the data to the previous status, but it cannot recover other system status such as the distribution of the region server to a specific time point. Besides, the historical record based for recovering the system to a specific time point is only the record in a period of time, that is, when recovering the system, it can only recover the data using the period of time as a unit. Therefore, it cannot recover the data to a specific time point. Base of the above content, in the present technology field, it requires a method for recovering the system status to the same time point for the non-relational database, and ensuring that the recovery of the system status has consistency.